package com.ruoyi.project.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.system.mapper.PubCodetableMapper;
import com.ruoyi.project.system.domain.PubCodetable;
import com.ruoyi.project.system.service.IPubCodetableService;

/**
 * 码Service业务层处理
 * 
 * @author ruoyi
 * @date 2019-12-23
 */
@Service
public class PubCodetableServiceImpl implements IPubCodetableService 
{
    @Autowired
    private PubCodetableMapper pubCodetableMapper;

    /**
     * 查询码
     * 
     * @param code 码ID
     * @return 码
     */
    @Override
    public PubCodetable selectPubCodetableById(String code)
    {
        return pubCodetableMapper.selectPubCodetableById(code);
    }

    /**
     * 查询码列表
     * 
     * @param pubCodetable 码
     * @return 码
     */
    @Override
    public List<PubCodetable> selectPubCodetableList(PubCodetable pubCodetable)
    {
        return pubCodetableMapper.selectPubCodetableList(pubCodetable);
    }

    /**
     * 新增码
     * 
     * @param pubCodetable 码
     * @return 结果
     */
    @Override
    public int insertPubCodetable(PubCodetable pubCodetable)
    {
        return pubCodetableMapper.insertPubCodetable(pubCodetable);
    }

    /**
     * 修改码
     * 
     * @param pubCodetable 码
     * @return 结果
     */
    @Override
    public int updatePubCodetable(PubCodetable pubCodetable)
    {
        return pubCodetableMapper.updatePubCodetable(pubCodetable);
    }

    /**
     * 批量删除码
     * 
     * @param codes 需要删除的码ID
     * @return 结果
     */
    @Override
    public int deletePubCodetableByIds(String[] codes)
    {
        return pubCodetableMapper.deletePubCodetableByIds(codes);
    }

    /**
     * 删除码信息
     * 
     * @param code 码ID
     * @return 结果
     */
    @Override
    public int deletePubCodetableById(String code)
    {
        return pubCodetableMapper.deletePubCodetableById(code);
    }
}
